package com.linjiang;

import com.linjiang.proxy.ProxyFactory;

public class ConsumerRun {

    public static void main(String[] args) {
        //启动服务器
        /*HttpServer server = new HttpServer();
        server.start("lcalhost",8087);*/

        //获取接口的代理对象
        HelloService helloService = ProxyFactory.getProxy(HelloService.class);
        //通过代理对象调用接口的方法发起请求
        String result = helloService.sayHello("linjiang");
        System.out.println("请求返回结果："+result);
    }
}
